package com.ruoyi.web.controller.teacher;

import com.ruoyi.common.core.domain.entity.SysMenu;
import com.ruoyi.common.core.domain.entity.SysRole;
import com.ruoyi.service.UserRoleService;
import com.ruoyi.system.service.ISysRoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/userRole")
public class UserRoleController {

    @Autowired
    private UserRoleService userRoleService;

    @GetMapping("selectMenuByUserIdAndRoleId")
    public List<SysMenu> selectMenuByUserIdAndRoleId(Long userId,Long roleId) {


        return userRoleService.selectMenusByUserId(userId,roleId);
    }
}
